#!/bin/sh

if [ $# == 0 ]; then
    common=3
else 
    common=$1
fi

lists="*LongList ShortDecreaseList BuyingOnWeaknessList"

>tmp$$
cat $lists |cut -d',' -f1 |awk '{print $1}' |sort |uniq -d |while read line
do
   if [ `grep -w $line $lists |wc -l` -ge $common ]; then
	echo $line >> tmp$$
   fi
done
./listquote.sh tmp$$
\rm tmp$$ 
